package com.procurement.orders.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.procurement.orders.mapper.PcmApplicationDetailMapper;
import com.procurement.orders.domain.PcmApplicationDetail;
import com.procurement.orders.service.IPcmApplicationDetailService;

/**
 * 申请明细Service业务层处理
 * 
 * @author liyang
 * @date 2023-12-07
 */
@Service
public class PcmApplicationDetailServiceImpl implements IPcmApplicationDetailService 
{
    @Autowired
    private PcmApplicationDetailMapper pcmApplicationDetailMapper;

    /**
     * 查询申请明细
     * 
     * @param detailId 申请明细主键
     * @return 申请明细
     */
    @Override
    public PcmApplicationDetail selectPcmApplicationDetailByDetailId(Long detailId)
    {
        return pcmApplicationDetailMapper.selectPcmApplicationDetailByDetailId(detailId);
    }

    /**
     * 查询申请明细列表
     * 
     * @param pcmApplicationDetail 申请明细
     * @return 申请明细
     */
    @Override
    public List<PcmApplicationDetail> selectPcmApplicationDetailList(PcmApplicationDetail pcmApplicationDetail)
    {
        return pcmApplicationDetailMapper.selectPcmApplicationDetailList(pcmApplicationDetail);
    }

    /**
     * 新增申请明细
     * 
     * @param pcmApplicationDetail 申请明细
     * @return 结果
     */
    @Override
    public int insertPcmApplicationDetail(PcmApplicationDetail pcmApplicationDetail)
    {
        return pcmApplicationDetailMapper.insertPcmApplicationDetail(pcmApplicationDetail);
    }

    /**
     * 修改申请明细
     * 
     * @param pcmApplicationDetail 申请明细
     * @return 结果
     */
    @Override
    public int updatePcmApplicationDetail(PcmApplicationDetail pcmApplicationDetail)
    {
        return pcmApplicationDetailMapper.updatePcmApplicationDetail(pcmApplicationDetail);
    }

    /**
     * 批量删除申请明细
     * 
     * @param detailIds 需要删除的申请明细主键
     * @return 结果
     */
    @Override
    public int deletePcmApplicationDetailByDetailIds(Long[] detailIds)
    {
        return pcmApplicationDetailMapper.deletePcmApplicationDetailByDetailIds(detailIds);
    }

    /**
     * 删除申请明细信息
     * 
     * @param detailId 申请明细主键
     * @return 结果
     */
    @Override
    public int deletePcmApplicationDetailByDetailId(Long detailId)
    {
        return pcmApplicationDetailMapper.deletePcmApplicationDetailByDetailId(detailId);
    }
}
